<?php
$arquivos[0] = "../Scripts/jquery-1.4.1.min.js";
$arquivos[1] = "../Scripts/balao.js";
$arquivos[2] = "../Scripts/excanvas.js";
$arquivos[3] = "../mm_menu.js";
$arquivos[4] = "../Scripts/jquery.cycle.all.min.js";
$arquivos[5] = "../Scripts/maskedinput.min.js";
$arquivos[6] = "../Scripts/autocomplete/jquery-ui-1.8.5.custom.min.js";
$arquivos[7] = "../Scripts/calendario2/jquery-ui-1.7.2.custom.min.js";
$arquivos[8] = "../Scripts/colorbox/colorbox-min.js";
$arquivos[9] = "../Scripts/uploadify/jquery.uploadify.v2.1.0.min.js";
$arquivos[10] = "../Scripts/uploadify/swfobject.js";

$file = $arquivos[$_GET['file']];

if (is_file($file)) {
$ext = end(explode(".", $file));

switch($ext) {
case 'html':$type = 'text/html';break;
case 'css':$type = 'text/css';break;
case 'txt':$type = 'text/plain';break;
case 'js':$type = 'text/javascript';break;
}

ob_start("ob_gzhandler");
ob_start("compress");
header("Content-type: $type charset: UTF-8");
header("Cache-Control: must-revalidate");
$off = 1800; # Set to a reaonable value later, say 3600 (1 hr);
$exp = "Expires: " . gmdate("D, d M Y H:i:s", time() + $off) . " GMT";
header($exp);

require_once($file);
}
?>